//
//  HCGGGGGGGViewController.m
//  HappyChildren
//
//  Created by jiayibai-02por on 2017/6/14.
//  Copyright © 2017年 WillyZhao. All rights reserved.
//

#import "HCGGGGGGGViewController.h"

@interface HCGGGGGGGViewController () <UIWebViewDelegate>

@end

@implementation HCGGGGGGGViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    
    UIWebView *we = [[UIWebView alloc] initWithFrame:CGRectMake(0, 0, self.centerView.frame.size.width, self.centerView.frame.size.height)];
    we.delegate = self;
    
    [we loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:@"http://www.cdjiayibai.com/home/mall/index"]]];
    
    [self.centerView addSubview:we];
    
    
    // Do any additional setup after loading the view.
}


-(BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType {
    
    if ([request.URL.absoluteString isEqualToString:@"http://www.cdjiayibai.com/home/mall/index"]) {
        return YES;
    }else{
        NSLog(@"qiqiqiqi=-----%@,",request.URL);
        return NO;
    }
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
